<div>
    <h2>
        <span>Cycle Plans</span>
        <button class="btn btn-primary float-right jh-create-entity create-cycle-plan" [routerLink]="['/', { outlets: { popup: ['cycle-plan-new'] } }]">
            <span class="fa fa-plus"></span>
            <span >
            Create new Cycle Plan
            </span>
        </button>
    </h2>
    <jhi-alert></jhi-alert>
    <div class="row">
    </div>
    <br/>
    <div class="table-responsive" *ngIf="cyclePlans">
        <table class="table table-striped">
            <thead>
            <tr jhiSort [(predicate)]="predicate" [(ascending)]="reverse" [callback]="transition.bind(this)">
            <th jhiSortBy="id"><span>ID</span> <span class="fa fa-sort"></span></th>
            <th jhiSortBy="kindId"><span>Kind Id</span> <span class="fa fa-sort"></span></th>
            <th jhiSortBy="subType"><span>Sub Type</span> <span class="fa fa-sort"></span></th>
            <th jhiSortBy="allTime"><span>All Time</span> <span class="fa fa-sort"></span></th>
            <th jhiSortBy="startTime"><span>Start Time</span> <span class="fa fa-sort"></span></th>
            <th jhiSortBy="endTime"><span>End Time</span> <span class="fa fa-sort"></span></th>
            <th jhiSortBy="name"><span>Name</span> <span class="fa fa-sort"></span></th>
            <th jhiSortBy="data"><span>Data</span> <span class="fa fa-sort"></span></th>
            <th jhiSortBy="content"><span>Content</span> <span class="fa fa-sort"></span></th>
            <th jhiSortBy="winTimes"><span>Win Times</span> <span class="fa fa-sort"></span></th>
            <th jhiSortBy="alwaysFail"><span>Always Fail</span> <span class="fa fa-sort"></span></th>
            <th jhiSortBy="alwaysWin"><span>Always Win</span> <span class="fa fa-sort"></span></th>
            <th jhiSortBy="isWin"><span>Is Win</span> <span class="fa fa-sort"></span></th>
            <th jhiSortBy="date"><span>Date</span> <span class="fa fa-sort"></span></th>
            <th></th>
            </tr>
            </thead>
            <tbody>
            <tr *ngFor="let cyclePlan of cyclePlans ;trackBy: trackId">
                <td><a [routerLink]="['../cycle-plan', cyclePlan.id ]">{{cyclePlan.id}}</a></td>
                <td>{{cyclePlan.kindId}}</td>
                <td>{{cyclePlan.subType}}</td>
                <td>{{cyclePlan.allTime}}</td>
                <td>{{cyclePlan.startTime}}</td>
                <td>{{cyclePlan.endTime}}</td>
                <td>{{cyclePlan.name}}</td>
                <td>{{cyclePlan.data}}</td>
                <td>{{cyclePlan.content}}</td>
                <td>{{cyclePlan.winTimes}}</td>
                <td>{{cyclePlan.alwaysFail}}</td>
                <td>{{cyclePlan.alwaysWin}}</td>
                <td>{{cyclePlan.isWin}}</td>
                <td>{{cyclePlan.date}}</td>
                <td class="text-right">
                    <div class="btn-group flex-btn-group-container">
                        <button type="submit"
                                [routerLink]="['../cycle-plan', cyclePlan.id ]"
                                class="btn btn-info btn-sm">
                            <span class="fa fa-eye"></span>
                            <span class="d-none d-md-inline">View</span>
                        </button>
                        <button type="submit"
                                [routerLink]="['/', { outlets: { popup: 'cycle-plan/'+ cyclePlan.id + '/edit'} }]"
                                replaceUrl="true"
                                class="btn btn-primary btn-sm">
                            <span class="fa fa-pencil"></span>
                            <span class="d-none d-md-inline">Edit</span>
                        </button>
                        <button type="submit"
                                [routerLink]="['/', { outlets: { popup: 'cycle-plan/'+ cyclePlan.id + '/delete'} }]"
                                replaceUrl="true"
                                class="btn btn-danger btn-sm">
                            <span class="fa fa-remove"></span>
                            <span class="d-none d-md-inline">Delete</span>
                        </button>
                    </div>
                </td>
            </tr>
            </tbody>
        </table>
    </div>
        <div *ngIf="cyclePlans && cyclePlans.length">
            <div class="row justify-content-center">
                <jhi-item-count [page]="page" [total]="queryCount" [maxSize]="5" [itemsPerPage]="itemsPerPage"></jhi-item-count>
            </div>
            <div class="row justify-content-center">
                <ngb-pagination [collectionSize]="totalItems" [maxSize]="5" [pageSize]="itemsPerPage" [(page)]="page" (pageChange)="loadPage(page)"></ngb-pagination>
            </div>
        </div>
</div>
